const dateFormat = function (date, format) {
    let _time = '';

    let _year = date.getFullYear().toString();
    let _month = (date.getMonth() + 1).toString().padStart(2, '0');
    let _day = date.getDate().toString().padStart(2, '0');
    let _hour = date.getHours().toString().padStart(2, '0');
    let _minute = date.getMinutes().toString().padStart(2, '0');
    let _second = date.getSeconds().toString().padStart(2, '0');


    

    if (!format) {
        _time = _year+'n' + _month+'yue' + _day;
    }

    return _time;
};

export default dateFormat;